<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2017/1/17
 * Time: 10:53
 */
//echo strlen(md5(12))."<br>";
//echo strlen(md5(1).md5(2));
class fun{
    public  function hexToStr($hex)
    {
        $bin="";
        for($i=0; $i<strlen($hex)-1; $i+=2)
        {
            $bin.=chr(hexdec($hex[$i].$hex[$i+1]));
        }
        return $bin;
    }
}
$fun=new fun();
$fun->hexToStr(10);